<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title>闭包</title>
</head>

<script>
 function t1(){
     var age = 20;
     function t2(){
         alert(age);
     }
     return t2;
//     alert(t2);
 }


    var tmp  = t1();

    var age = 99;

    tmp();


</script>
<body>

</body>
</html>